//PersonTest.java
package com.ylaihui.oop1;

public class PersonTest {
	public static void main(String[] args) {
		Person p1 = new Person();
		p1.name = "John";
		p1.age = 22;
		p1.talk("中文");
		
	}
}

// 设计类
class Person{
	String name;
	int age;
	boolean isMale;
	
	public void eat() {
		System.out.println("人吃...");
	}
	public void talk(String language) {
		System.out.println("人使用" + language + "交流");
	}
}